﻿using System;
using SharpSqlAnalyzer.nodes;

namespace SharpSqlAnalyzer.stmt
{
	// Token: 0x020000AD RID: 173
	public class TExitStmt : TCustomSqlStatement
	{
		// Token: 0x0600056F RID: 1391 RVA: 0x002FD05A File Offset: 0x002FB25A
		public void setExitlabelName(TObjectName n)
		{
			this.exitlabelName = n;
		}

		// Token: 0x06000570 RID: 1392 RVA: 0x002FD063 File Offset: 0x002FB263
		public TExitStmt() : this(EDbVendor.dbvoracle)
		{
		}

		// Token: 0x06000571 RID: 1393 RVA: 0x002FD06D File Offset: 0x002FB26D
		public TExitStmt(EDbVendor dbvendor) : base(dbvendor)
		{
			this.sqlstatementtype = ESqlStatementType.sst_exitstmt;
		}

		// Token: 0x06000572 RID: 1394 RVA: 0x002FD07E File Offset: 0x002FB27E
		internal override void buildsql()
		{
		}

		// Token: 0x06000573 RID: 1395 RVA: 0x002FD080 File Offset: 0x002FB280
		internal override void clear()
		{
		}

		// Token: 0x06000574 RID: 1396 RVA: 0x002FD082 File Offset: 0x002FB282
		internal override string getasprettytext()
		{
			return "";
		}

		// Token: 0x06000575 RID: 1397 RVA: 0x002FD089 File Offset: 0x002FB289
		internal virtual void iterate(TVisitorAbs pvisitor)
		{
		}

		// Token: 0x170000DB RID: 219
		// (get) Token: 0x06000577 RID: 1399 RVA: 0x002FD094 File Offset: 0x002FB294
		// (set) Token: 0x06000576 RID: 1398 RVA: 0x002FD08B File Offset: 0x002FB28B
		public virtual TObjectName ExitlabelName
		{
			get
			{
				return this.exitlabelName;
			}
			set
			{
				this.exitlabelName = value;
			}
		}

		// Token: 0x170000DC RID: 220
		// (get) Token: 0x06000578 RID: 1400 RVA: 0x002FD09C File Offset: 0x002FB29C
		// (set) Token: 0x06000579 RID: 1401 RVA: 0x002FD0A4 File Offset: 0x002FB2A4
		public virtual TExpression WhenCondition
		{
			get
			{
				return this.whenCondition;
			}
			set
			{
				this.whenCondition = value;
			}
		}

		// Token: 0x0600057A RID: 1402 RVA: 0x002FD0AD File Offset: 0x002FB2AD
		public override void init(object arg1)
		{
			this.whenCondition = (TExpression)arg1;
		}

		// Token: 0x0600057B RID: 1403 RVA: 0x002FD0BB File Offset: 0x002FB2BB
		public override int doParseStatement(TCustomSqlStatement psql)
		{
			base.doParseStatement(psql);
			if (this.whenCondition != null)
			{
				this.whenCondition.doParse(this, ESqlClause.unknown);
			}
			return 0;
		}

		// Token: 0x0600057C RID: 1404 RVA: 0x002FD0DB File Offset: 0x002FB2DB
		public override void accept(TParseTreeVisitor v)
		{
			v.preVisit(this);
			v.postVisit(this);
		}

		// Token: 0x0600057D RID: 1405 RVA: 0x002FD0EB File Offset: 0x002FB2EB
		public override void acceptChildren(TParseTreeVisitor v)
		{
			v.preVisit(this);
			v.postVisit(this);
		}

		// Token: 0x04001147 RID: 4423
		private TObjectName exitlabelName;

		// Token: 0x04001148 RID: 4424
		private TExpression whenCondition;
	}
}
